<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<script>



    var matrix = [
        [1, 3, 5, 7],
        [10, 11, 16, 20],
        [23, 30, 34, [100,[1,3,3],102]]
    ];
    // var matrix = [
    //     1, 3, 5, [1, 3, 5, 7],
    // ];
    function find(arr,target) {
        for(let i of arr){
            if(i.constructor === Number){
                if(i === target){
                    document.write(target)
                }
            }else if(i.constructor === Array){
                find(i,target)
            }
        }
    }
    find(matrix,5);

    // [a:10,b:4,c:8]
</script>

</body>
</html>